package com.ssm.gbq.mapper;

import com.ssm.gbq.model.Flowers;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface FlowersMapper {
    /**
     * 分页查询
     */
    List<Flowers> showFlowersByPage(@Param("flowers") Flowers flowers, @Param("currentPage")int currentPage, @Param("pageSize")int pageSize)throws Exception;

    /**
     * 查询全部
     */
    List<Flowers> showFlowersTable();

    /**
     * 通过id查询
     */
    Flowers getFlowersById(Integer id);

    /**
     * 修改
     */
    int updateFlower(Flowers flowers)throws Exception;

    /**
     * 添加
     */
    int addFlower(Flowers flowers)throws Exception;

    /**
     * 根据id删除
     */
    int delFlower(Integer id)throws Exception;

    /**
     * 查询数据条数
     */
    int getFlowersCount(@Param("flowers")Flowers flowers);

    /**
     * 批量删除
     */
    int deleteFlowers(List<Integer> ids);

}
